package com.haina.shop.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;

import lombok.*;

/**
 * 用户表
 * @TableName tz_user
 */
@TableName(value ="tz_user")
@Data
@AllArgsConstructor
@NoArgsConstructor
public class User implements Serializable {
    public User(String nickName, String realName, String userMail, String loginPassword, String payPassword, String userMobile, Date modifyTime, Date userRegtime, String userRegip, Date userLasttime, String userLastip, String userMemo, String sex, String birthDate, String pic, Integer status, Integer score) {
        this.nickName = nickName;
        this.realName = realName;
        this.userMail = userMail;
        this.loginPassword = loginPassword;
        this.payPassword = payPassword;
        this.userMobile = userMobile;
        this.modifyTime = modifyTime;
        this.userRegtime = userRegtime;
        this.userRegip = userRegip;
        this.userLasttime = userLasttime;
        this.userLastip = userLastip;
        this.userMemo = userMemo;
        this.sex = sex;
        this.birthDate = birthDate;
        this.pic = pic;
        this.status = status;
        this.score = score;
    }

    /**
     * ID
     */
    @TableId(value = "user_id")
    private String userId;

    /**
     * 用户昵称
     */
    @TableField(value = "nick_name")
    private String nickName;

    /**
     * 真实姓名
     */
    @TableField(value = "real_name")
    private String realName;

    /**
     * 用户邮箱
     */
    @TableField(value = "user_mail")
    private String userMail;

    /**
     * 登录密码
     */
    @TableField(value = "login_password")
    private String loginPassword;

    /**
     * 支付密码
     */
    @TableField(value = "pay_password")
    private String payPassword;

    /**
     * 手机号码
     */
    @TableField(value = "user_mobile")
    private String userMobile;

    /**
     * 修改时间
     */
    @TableField(value = "modify_time")
    private Date modifyTime;

    /**
     * 注册时间
     */
    @TableField(value = "user_regtime")
    private Date userRegtime;

    /**
     * 注册IP
     */
    @TableField(value = "user_regip")
    private String userRegip;

    /**
     * 最后登录时间
     */
    @TableField(value = "user_lasttime")
    private Date userLasttime;

    /**
     * 最后登录IP
     */
    @TableField(value = "user_lastip")
    private String userLastip;

    /**
     * 备注
     */
    @TableField(value = "user_memo")
    private String userMemo;

    /**
     * M(男) or F(女)
     */
    @TableField(value = "sex")
    private String sex;

    /**
     * 例如：2009-11-27
     */
    @TableField(value = "birth_date")
    private String birthDate;

    /**
     * 头像图片路径
     */
    @TableField(value = "pic")
    private String pic;

    /**
     * 状态 1 正常 0 无效
     */
    @TableField(value = "status")
    private Integer status;

    /**
     * 用户积分
     */
    @TableField(value = "score")
    private Integer score;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}